<template>
  <div class="light-tech-dashboard">
    <div class="light-tech-header">
      <h1 class="light-tech-title">企业数字化解决方案</h1>
      <p class="light-tech-subtitle">赋能企业数字化转型的全面产品矩阵</p>
      <div class="light-tech-gradient-bar"></div>
    </div>

    <div class="light-tech-products-grid">
      <div 
        v-for="product in products" 
        :key="product.id" 
        class="light-tech-product-card"
        @click="redirectTo(product.url)"
        :style="{ '--hover-color': product.hoverColor }"
      >
        <div class="light-tech-card-glow"></div>
        <div class="light-tech-card-content">
          <div class="light-tech-logo-container">
            <div class="light-tech-logo" :style="{ background: product.logoBg }">
              <!-- SVG图标优先，字体图标作为回退 -->
              <svg v-if="product.svgIcon" v-html="product.svgIcon" class="tech-svg-icon" />
              <i v-else :class="product.icon"></i>
            </div>
          </div>
          <h3 class="light-tech-product-title">{{ product.title }}</h3>
          <p class="light-tech-product-desc">{{ product.description }}</p>
          <div class="light-tech-learn-more">
            了解更多 <svg class="arrow-icon" viewBox="0 0 24 24"><path d="M5 12h14M12 5l7 7-7 7"/></svg>
          </div>
        </div>
      </div>
    </div>

    <div class="light-tech-footer" v-if="false" >
      <p>© 2023 科技企业解决方案 | 赋能您的业务增长</p>
    </div>
  </div>
</template>

<script>
export default {
  name: 'appFastLink',
  data() {
    return {
      products: [
        // {
        //   id: 1,
        //   title: '智能ERP系统',
        //   description: '集成企业资源规划全流程，提供财务、供应链、生产制造等模块的一体化管理解决方案。',
        //   svgIcon: `<path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-8 14H7v-2h4v2zm0-4H7v-2h4v2zm0-4H7V7h4v2zm6 8h-4v-2h4v2zm0-4h-4v-2h4v2zm0-4h-4V7h4v2z"/>`,
        //   icon: 'fas fa-network-wired',
        //   logoBg: 'linear-gradient(135deg, #6e8efb, #a777e3)',
        //   hoverColor: '#6e8efb',
        //   url: 'https://erp.mdslyun.com/home'
        // },
        {
          id: 1,
          title: '云智能制造平台',
          description: '集成企业资源规划全流程，提供财务、供应链、生产制造等模块的一体化管理解决方案。',
          svgIcon: `<path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-8 14H7v-2h4v2zm0-4H7v-2h4v2zm0-4H7V7h4v2zm6 8h-4v-2h4v2zm0-4h-4v-2h4v2zm0-4h-4V7h4v2z"/>`,
          icon: 'fas fa-network-wired',
          logoBg: 'linear-gradient(135deg, #6e8efb, #a777e3)',
          hoverColor: '#6e8efb',
          url: 'http://120.46.12.231:8080/'
        },
        {
          id: 2,
          title: '协同OA平台',
          description: '高效办公自动化系统，实现流程审批、文档管理、即时通讯等功能的智能化协同。',
          svgIcon: `<path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM8 17c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm0-4c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm0-4c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm6 1H9.5v-1.5H14V9zm0 2.5H9.5V10H14v1.5zm0 2.5H9.5V12.5H14V15z"/>`,
          icon: 'fas fa-users-cog',
          logoBg: 'linear-gradient(135deg, #4facfe, #00f2fe)',
          hoverColor: '#4facfe',
          url: 'http://oa.mdslyun.com/'
        },
        {
          id: 3,
          title: '智能CRM系统',
          description: '客户关系管理平台，整合销售、营销和服务流程，提升客户满意度和业务转化率。',
          svgIcon: `<path d="M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"/>`,
          icon: 'fas fa-handshake',
          logoBg: 'linear-gradient(135deg, #f093fb, #f5576c)',
          hoverColor: '#f093fb',
          url: 'http://crm.metaverseants.com/login'
        },
        {
          id: 4,
          title: '企业商城',
          description: 'B2B/B2C电子商务解决方案，提供个性化产品、智能推荐和全渠道销售能力。',
          svgIcon: `<path d="M7 18c-1.1 0-1.99.9-1.99 2S5.9 22 7 22s2-.9 2-2-.9-2-2-2zM1 2v2h2l3.6 7.59-1.35 2.45c-.16.28-.25.61-.25.96 0 1.1.9 2 2 2h12v-2H7.42c-.14 0-.25-.11-.25-.25l.03-.12.9-1.63h7.45c.75 0 1.41-.41 1.75-1.03l3.58-6.49c.08-.14.12-.31.12-.48 0-.55-.45-1-1-1H5.21l-.94-2H1zm16 16c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2z"/>`,
          icon: 'fas fa-shopping-cart',
          logoBg: 'linear-gradient(135deg, #43e97b, #38f9d7)',
          hoverColor: '#43e97b',
          url: 'https://shop.yamdyun.com/'
        },
        {
          id: 5,
          title: '商城商户端',
          description: '为商户提供商品管理、订单处理、数据分析和营销工具的一站式后台系统。',
          svgIcon: `<path d="M3 13h2v-2H3v2zm0 4h2v-2H3v2zm0-8h2V7H3v2zm4 4h14v-2H7v2zm0 4h14v-2H7v2zM7 7v2h14V7H7z"/>`,
          icon: 'fas fa-store',
          logoBg: 'linear-gradient(135deg, #ff9a9e, #fad0c4)',
          hoverColor: '#ff9a9e',
          url: 'https://shopmer.yamdyun.com/'
        },
        {
          id: 6,
          title: '客户数据分析平台',
          description: '企业级管理工具，提供客户数据可视化、智能分析和智能报表功能，助力数据驱动决策。',
          svgIcon: `<path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 17H7v-7h2v7zm4 0h-2V7h2v10zm4 0h-2v-4h2v4z"/>`,
          icon: 'fas fa-chart-line',
          logoBg: 'linear-gradient(135deg, #a18cd1, #fbc2eb)',
          hoverColor: '#a18cd1',
          url: 'http://admin.metaverseants.com'
        }
      ]
    }
  },
  methods: {
    redirectTo(url) {
      window.open(url, '_blank');
    }
  }
}
</script>

<style>
:root {
  --light-bg: #f8fafc;
  --card-bg: #ffffff;
  --text-primary: #1e293b;
  --text-secondary: #64748b;
  --card-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--light-bg);
  color: var(--text-primary);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', sans-serif;
}

.light-tech-dashboard {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
}

.light-tech-header {
  text-align: center;
  margin-bottom: 3rem;
  position: relative;
}

.light-tech-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: #1e293b;
  position: relative;
  display: inline-block;
}

.light-tech-title::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: linear-gradient(90deg, #4facfe, #00f2fe);
  border-radius: 2px;
}

.light-tech-subtitle {
  font-size: 1.2rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.light-tech-gradient-bar {
  height: 4px;
  width: 100px;
  background: linear-gradient(90deg, #6e8efb, #a777e3);
  margin: 0 auto;
  border-radius: 2px;
  opacity: 0.8;
}

.light-tech-products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  margin-bottom: 3rem;
}

.light-tech-product-card {
  background: var(--card-bg);
  border-radius: 12px;
  padding: 1.5rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  box-shadow: var(--card-shadow);
  border: 1px solid rgba(0, 0, 0, 0.05);
}

.light-tech-product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.12);
  border-color: rgba(0, 0, 0, 0.1);
}

.light-tech-product-card:hover .light-tech-card-glow {
  opacity: 0.3;
}

.light-tech-card-glow {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at center, var(--hover-color), transparent 70%);
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 0;
}

.light-tech-card-content {
  position: relative;
  z-index: 1;
}

.light-tech-logo-container {
  display: flex;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.light-tech-logo {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: white;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.light-tech-logo svg {
  width: 40px;
  height: 40px;
  fill: currentColor;
}

/* 字体图标回退样式 */
.light-tech-logo i {
  @supports not (font-variation-settings: normal) {
    display: none;
  }
}

.light-tech-product-card:hover .light-tech-logo {
  transform: scale(1.1);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.light-tech-product-title {
  font-size: 1.5rem;
  font-weight: 500;
  margin-bottom: 1rem;
  text-align: center;
  color: var(--text-primary);
}

.light-tech-product-desc {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
  text-align: center;
}

.light-tech-learn-more {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--hover-color);
  font-weight: 500;
  transition: all 0.3s ease;
}

.light-tech-learn-more .arrow-icon {
  width: 16px;
  height: 16px;
  margin-left: 8px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.3s ease;
}

.light-tech-product-card:hover .light-tech-learn-more {
  transform: translateX(5px);
}

.light-tech-product-card:hover .arrow-icon {
  transform: translateX(3px);
}

.light-tech-footer {
  text-align: center;
  padding: 2rem 0;
  color: var(--text-secondary);
  font-size: 0.9rem;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
}

@media (max-width: 768px) {
  .light-tech-products-grid {
    grid-template-columns: 1fr;
  }
  
  .light-tech-title {
    font-size: 2rem;
  }
}

/* 字体图标不可用时的完全回退方案 */
@supports not (font-variation-settings: normal) {
  .light-tech-logo {
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
  }
}
</style>